package com.zhfk.a.controller;

import com.zhfk.common.model.User;
import com.zhfk.common.result.ResponseResult;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping()
public class ResourceController {

    @GetMapping("/res1")
    public ResponseResult<String> getResource1() {
        return ResponseResult.success("resource-A-1");
    }


    @GetMapping("/res2")
     public User getResource2() {
        User user = new User();
        user.setId(1L);
        user.setName("zhfk");
        return user;
     }

}
